package com.oi.test01.entity;

import java.util.Map;

/**
 * @author bin
 * @date 2025 - 03 -19
 **/
public class Demo1 {
    private String name;
    private int age;
    private String sex;

    public Demo1() {
    }

    public Demo1(String name, int age, String sex) {
        this.name = name;
        this.age = age;
        this.sex = sex;
    }
    public Demo1(Map<String ,Object> map){
        this.name= (String) map.get("name");
        this.age= (int) map.get("age");
        this.sex= (String) map.get("sex");
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public int getAge() {
        return age;
    }

    public void setAge(int age) {
        this.age = age;
    }

    public String getSex() {
        return sex;
    }

    public void setSex(String sex) {
        this.sex = sex;
    }

    @Override
    public String toString() {
        return "demo1{" +
                "name='" + name + '\'' +
                ", age=" + age +
                ", sex='" + sex + '\'' +
                '}';
    }
}
